﻿using System;
using System.Collections.Generic;
using System.Linq;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Audio;
using Microsoft.Xna.Framework.Content;
using Microsoft.Xna.Framework.GamerServices;
using Microsoft.Xna.Framework.Graphics;
using Microsoft.Xna.Framework.Input;
using Microsoft.Xna.Framework.Media;
using Microsoft.Xna.Framework.Net;
using Microsoft.Xna.Framework.Storage;


namespace CivCraft
{
    /// <summary>
    /// This is a game component that implements IUpdateable.
    /// </summary>
    public class Unit
    {
        public Map Map
        {
            get {return map;}
        }
        Map map;

        public int posX;
        public int posY;
        public int targetX;
        public int targetY;
        public int[,] movable;


        private void unitCreate(int type, int x, int y){
            
            //Call Server for 
            
        
        
        
        
        }
        public void getState(int type, int x, int y){

            //send packet; recieve status


            return;
        }
        private void unitMove(){}
        private void unitSkill(){}

      
        private void SendMsg(int type, int com, int px, int py, int tx, int ty){}

        public Unit()
        {
            // TODO: Construct any child components here
        }

        /// <summary>
        /// Allows the game component to perform any initialization it needs to before starting
        /// to run.  This is where it can query for any required services and load content.
        /// </summary>
        

        /// <summary>
        /// Allows the game component to update itself.
        /// </summary>
        /// <param name="gameTime">Provides a snapshot of timing values.</param>
        public void Update(GameTime gameTime)
        {
            // TODO: Add your update code here

            
        }
        public void Draw(GameTime gameTime, SpriteBatch spriteBatch)
        {

        }
    }
}